<?php
$this->breadcrumbs=array(
	'Cadernos'=>array('index'),
	$model->id,
);

$this->menu=array(
	array('label'=>'List Caderno', 'url'=>array('index')),
	array('label'=>'Create Caderno', 'url'=>array('create')),
	array('label'=>'Update Caderno', 'url'=>array('update', 'id'=>$model->id)),
	array('label'=>'Delete Caderno', 'url'=>'#', 'linkOptions'=>array('submit'=>array('delete','id'=>$model->id),'confirm'=>'Are you sure you want to delete this item?')),
	array('label'=>'Manage Caderno', 'url'=>array('admin')),
);
?>

<h1>Configura&ccedil;&atilde;o do Caderno </h1>

<h2><?php echo $model->titulo; ?></h2>

<p>Selecione quais disciplinas deseja adicionar ao modelo de caderno:</p>

<?php echo CHtml::beginForm(); ?>  
	<div>
		<table>
	    <?php
	     
	    	/*
	    	$assuntos = Assunto::model()->findAll();
	    	
	    	echo CHtml::checkBoxList('Disciplinas','Disciplinas', CHtml::listData($assuntos, 'id', 'nome'),
			  array('template'=>'<tr><td>{label}</td><td>{input}</td></tr>')
			);
			*/
			
			$dataProvider=new CActiveDataProvider('Assunto');
			$this->widget('zii.widgets.CListView', array(
				'dataProvider'=>$dataProvider,
				'itemView'=>'_selectAssuntos',
			)); 
			
			
 		?> 
 		</table>
	</div>
	<div class="action">
	    <?php echo CHtml::submitButton("Confirmar"); ?>
	</div>
<?php echo CHtml::endForm(); ?>

